<template>

  <el-row>
    <el-col :span="12"><div class="grid-content bg-purple" id="main1" style="width:700px;height:550px;margin-top:50px;margin-left:70px" ></div></el-col>
    <el-col :span="12"><div class="grid-content bg-purple-light" id="main" style="width:600px;height:500px;margin-left:70px;margin-top:70px"><Expqua1></Expqua1></div></el-col>
  </el-row>

</template>

<script>
  import Expqua1 from "../../components/Expqua1";
  export default {
    name: "Expqua",
    components: {Expqua1},
    mounted() {
      this.init()
    },

    methods: {
      init: function () {
        var myChart = this.$echarts.init(document.getElementById('main1'));
        myChart.setOption({
          title:{
            text:'2020年每个月快递数量'
          },
          tooltip: {},
          xAxis: {
            type: 'category',
            boundaryGap: false,
            data: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul','Aug','Sept','Oct','Nov','Dec']
          },
          yAxis: {
            type: 'value'
          },
          series: [{
            name:'业务量（亿件）',
            color:'#6ade23',
            data: [37.8, 27.7, 59.8, 65.0, 73.8, 74.7, 69.4, 72.4, 80.9, 82.3, 97.3, 92.5],
            type: 'line',
            areaStyle: {}
          }]
        });

        myChart.setOption(option);
      }
    },
    data() {
      return {
        tableData: [{
          date: '2021-05-02',
          name: '搜索引擎',
          address: '1666236次',
          type:123
        }, {
          date: '2021-05-04',
          name: '直接访问',
          address: '1727747次',
          type:456
        }]
      }
    }



    /* mounted(){
         var dom= document.getElementById('Expqua');
         var chart=this.$echarts.init(dom);
         var option = {
           title:{
             text:'2020年快递数量'
           },
           tooltip: {},
           xAxis: {
             type: 'category',
             boundaryGap: false,
             data: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul','Aug','Sept','Oct','Nov','Dec']
           },
           yAxis: {
             type: 'value'
           },
           series: [{
             name:'业务量（亿件）',
             data: [37.8, 27.7, 59.8, 65.0, 73.8, 74.7, 69.4, 72.4, 80.9, 82.3, 97.3, 92.5],
             type: 'line',
             areaStyle: {}
           }]
         };
       chart.setOption(option);
     }*/
  }
</script>

<style scoped>

  </style>
